<?

if( !$_POST[OBJ] ){
	echo "ERROR : Post parameter(OBJ) doesn't exist";
	exit;
}

$obj = unserialize(stripslashes($_POST[OBJ]));

echo"
        <canssContent:media>
            <dc:creator> {$obj[1]}</dc:creator>
            <dc:date>{$obj[2]}</dc:date>
            <dc:description>{$obj[3]}</dc:description>
            <dc:format>{$obj[4]}</dc:format>
            <dc:identifier>{$obj[5]}</dc:identifier>
            <dc:language>{$obj[6]}</dc:language>
            <dc:publisher>{$obj[7]}</dc:publisher>
            <dc:rights>{$obj[8]}</dc:rights>
            <dc:source dcterms:scheme=\"{$obj[9]}\">{$obj[10]}</dc:source>
            <dc:subject>{$obj[11]}</dc:subject>
            <dc:title>{$obj[12]}</dc:title>
            <dc:type>{$obj[13]}</dc:type>
            <xmp:baseURL>{$obj[14]}</xmp:baseURL>
            <xmp:CreateDate>{$obj[15]}</xmp:CreateDate>
            <xmp:Identifier>{$obj[5]}</xmp:Identifier>
            <xmp:Rating>{$obj[16]}</xmp:Rating>
            <xmp:Thumbnails>
                <xmp:Thumbnail> <!-- multiple -->
                    <xmpGImg:format>
                    </xmpGImg:format>
                    <xmpGImg:width>
                    </xmpGImg:width>
                    <xmpGImg:height>
                    </xmpGImg:height>
                    <xmpGImg:image>
                    </xmpGImg:image>
                </xmp:Thumbnail>
            </xmp:Thumbnails>
            <canssContent:Thumbnail>{$obj[17]}</canssContent:Thumbnail>

            <xmpDM:duration>{$obj[18]}</xmpDM:duration>
            <xmpDM:copyright url=\"{$obj[19]}\">{$obj[20]}</xmpDM:copyright>
            <xmpDM:genre>{$obj[13]}</xmpDM:genre>

            <xmpDM:markers>
                <xmpDM:marker> <!-- 여러 마커들이 시간에 맞춰 차례대로 있어야 함.--> <!-- multiple -->
                    <xmpDM:comment>
                    </xmpDM:comment>
                    <xmpDM:name>
                    </xmpDM:name>
                    <xmpDM:startTime>
                    </xmpDM:startTime>
                    <xmpDM:location>
                    </xmpDM:location>
                </xmpDM:marker>
            </xmpDM:markers>

            <xmpDM:videoFrameSize>{$obj[21]}
                <stDim:w></stDim:w> <!-- media:content@height -->
                <stDim:h></stDim:h> <!-- media:content@width -->
            </xmpDM:videoFrameSize>
            <xmpDM:ModDate>{$obj[22]}</xmpDM:ModDate>

            <canssVideo:audioCodecs>{$obj[23]}</canssVideo:audioCodecs>
            <canssVideo:videoCodecs>{$obj[24]}</canssVideo:videoCodecs>
            <canssVideo:fileSize>{$obj[25]}</canssVideo:fileSize>

            <canssVideo:credit role=\"director\">  <!-- multiple -->
            </canssVideo:credit>

            <canssTV:p_startdate>{$obj[26]}</canssTV:p_startdate>
            <canssTV:p_enddate>{$obj[27]}</canssTV:p_enddate>
            <canssTV:isLive>{$obj[28]}</canssTV:isLive>
            <canssTV:isReRun>{$obj[29]}</canssTV:isReRun>
			
			<canssContentDescription:contentId>{$obj[0]}</canssContentDescription:contentId> 

            <canssContentDescription:status>
            </canssContentDescription:status>

            <canssContentDescription:views>

           </canssContentDescription:views>
            <canssContentDescription:rating>
            </canssContentDescription:rating>
            <canssContentDescription:owner>{$obj[30]}
            </canssContentDescription:owner>
            <canssContentDescription:location protocol=\"http\"> <!-- multiple -->
                <!-- xmp:Identifier 와 같은 값을 가진다.
                다른 것은 location은 다수의 위치를 지정할 수 있다는 점.
                다수를 지정하려면 또하나의 location element를 추가하자.-->
            </canssContentDescription:location>

            <canssContentDescription:price currencyCode=\"WON\">
            </canssContentDescription:price>
            <canssContentDescription:valid name='contract_1' start='2005-03-01T12:35:00' end='2006-03-01T12:35:00' /> <!-- multiple -->

        </canssContent:media>
";

?>
